package com.project.service;

import java.io.File;
import java.util.List;
import java.util.Set;

import com.project.vo.Picture;
import com.project.vo.Product;

public interface ProductService {

	/**
	 * add clothes
	 * @param product
	 * @return
	 */
	String add(Product product);
	String add(Product product, List<String> localPath);
	String add(Product product, Set pic);
	String add(Product product, List<File> pictures, List<String> picturesFileName);
	/**
	 * query all clothes by user id
	 * @param pageNum 
	 * @param pageSize 
	 * @return
	 */
	List<Product> queryAllByUserId(Integer user_id, int pageSize, int pageNum);
	List<Product> queryAllByUserId(Integer user_id);
	List<Product> queryAllProduct();
	List<Product> queryAllProduct(Integer pageNum, Integer pageSize);
	/**
	 * query by product id
	 * @param id
	 * @return
	 */
	Product queryById(Integer id);

	/**
	 * delete by product id
	 * @param id
	 * @return
	 */
	String delete(Integer id);

	/**
	 * update product info
	 * @param product
	 * @param pic 
	 * @return
	 */
	String update(Product product, Set pic);
	String update(Product product, List<File> pictures, List<String> picturesFileName);
	/**
	 * get count of product current
	 * @return
	 */
	Integer getCountUserProduct(Integer userId);
	/**
	 * 根据产品id查询所有的图片信息
	 * @param id
	 * @return
	 */
	List<Picture> queryPictureByProductId(Integer id);
	/**
	 * 根据图片id删除图片
	 * @param picture_id
	 * @return
	 */
	String imageDelete(Integer picture_id);
	
}
